<template>
  <div class="langselect">
    <van-dropdown-menu>
      <van-dropdown-item v-model="value" :options="option" />
    </van-dropdown-menu>
  </div>
</template>
<script>
export default {
  name: "LangSelect",
  props: {
    defaultValue: Number,
    default() {
      return 0;
    },
  },
  data() {
    return {
      value: 0,
      option: [
        { text: "简体中文", value: 0 },
        { text: "English", value: 1 },
      ],
    };
  },
  create() {
    this.value = this.$props.defaultValue;
  },
};
</script>
<style lang="less">
@base: 23.44rem;
.langselect {
  .van-dropdown-menu__bar {
    background-color: transparent;
    box-shadow: none;
    .van-dropdown-menu__title {
      font-size: 14 / @base;
      color: brown;
    }
  }
  .van-dropdown-item__option--active {
    color: brown;
  }
}
</style>
